$(function () {
    layui.use('form',function (obj) {
        var form = layui.form;
        $.post('/pages/back/role/list',{},function (obj) {
            for(var i = 0;i<obj.length;i++){
                $("#role").append("<input type='checkbox' name='rid' value='" + obj[i].rid + "'title='"+obj[i].title + "'>")
            }
            form.render();
        },'json')
    })
})
